USE CodeCamp44;
GO

--********************************************************
-- Drop Tables - start with 
--********************************************************
DECLARE @DropTables bit SET @DropTables = 0;
--DECLARE @DropTables bit SET @DropTables = 1;
IF @DropTables = 1 BEGIN

	DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)

	SET @TableName = N'cc_UsersInRoles'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_UsersInEventRoles'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_Roles'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_Roles4Events'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_Sponsors'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_SponsorImages'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_SessionPresenters'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_ScheduledSessions'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_TimeSlots'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_Rooms'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_Tasks_TimeSlots'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_TaskTimeSlots'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_Tasks'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_SessionTags'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_Tags'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_SpeakerRateEvent'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_Sessions'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_SpeakerRateSpeakers'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_SpeakerRateTalks'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_PresenterBiographies'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_Presenters'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_ShirtSizes'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_IndividualContributors'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_CommunitySponsors'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_Buildings'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_BannedTags'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_Events'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'cc_SiteUsers'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END


	--DECLARE @TableName NVARCHAR(128), @SqlCmd nvarchar(512)
	SET @TableName = N'__MigrationHistory'
	IF (EXISTS (SELECT name FROM sysobjects WHERE (name = @TableName) AND (type = 'U'))) BEGIN
		Set @SqlCmd = N'DROP TABLE ' + @TableName
		EXEC sp_executesql @SqlCmd
		PRINT 'dropped table ' + @TableName
	END ELSE BEGIN
		PRINT 'table ' + @TableName + ' not found for drop.'
	END

END;
GO

--********************************************************
--********************************************************
--********** CREATE SCHEMA
CREATE TABLE [dbo].[cc_BannedTags] (
    [Id] [int] NOT NULL IDENTITY,
    [Name] [nvarchar](128) NOT NULL,
    CONSTRAINT [PK_dbo.cc_BannedTags] PRIMARY KEY ([Id])
)
CREATE TABLE [dbo].[cc_Buildings] (
    [Id] [int] NOT NULL IDENTITY,
    [EventId] [int] NOT NULL,
    [Name] [nvarchar](128) NOT NULL,
    CONSTRAINT [PK_dbo.cc_Buildings] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_EventId] ON [dbo].[cc_Buildings]([EventId])
CREATE TABLE [dbo].[cc_Events] (
    [Id] [int] NOT NULL IDENTITY,
    [DisplayName] [nvarchar](128) NOT NULL,
    [ShortName] [nvarchar](32) NOT NULL,
    [DisplayDate] [nvarchar](64) NOT NULL,
    [DisplayLocation] [nvarchar](128) NOT NULL,
    [RegistrationUrl] [nvarchar](128) NOT NULL,
    [SessionSubmissionsOpen] [datetime] NOT NULL,
    [SessionSubmissionsClose] [datetime] NOT NULL,
    [EventIsPublic] [bit] NOT NULL,
    [DisplaySortOrder] [decimal](18, 2) NOT NULL,
    [EventStartDate] [datetime] NOT NULL,
    [DisconnectedPresenterProfileConnectionAllowed] [bit] NOT NULL,
    [ScheduleIsPublic] [bit] NOT NULL,
    [PriorEventProfileReuseAllowed] [bit] NOT NULL,
    [NonPublicEventPreviewRole] [nvarchar](30),
    [AgendaIsPublic] [bit] NOT NULL,
    [ScheduleVisibleToPresenters] [bit] NOT NULL,
    [SchedulePdfUrl] [nvarchar](172),
    CONSTRAINT [PK_dbo.cc_Events] PRIMARY KEY ([Id])
)
CREATE TABLE [dbo].[cc_CommunitySponsors] (
    [Id] [int] NOT NULL IDENTITY,
    [EventId] [int] NOT NULL,
    [Name] [nvarchar](128) NOT NULL,
    [Url] [nvarchar](1024) NOT NULL,
    CONSTRAINT [PK_dbo.cc_CommunitySponsors] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_EventId] ON [dbo].[cc_CommunitySponsors]([EventId])
CREATE TABLE [dbo].[cc_IndividualContributors] (
    [Id] [int] NOT NULL IDENTITY,
    [EventId] [int] NOT NULL,
    [FirstName] [nvarchar](128) NOT NULL,
    [LastName] [nvarchar](128) NOT NULL,
    CONSTRAINT [PK_dbo.cc_IndividualContributors] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_EventId] ON [dbo].[cc_IndividualContributors]([EventId])
CREATE TABLE [dbo].[cc_Presenters] (
    [Id] [int] NOT NULL IDENTITY,
    [EventId] [int] NOT NULL,
    [SiteUserId] [int],
    [FirstName] [nvarchar](128) NOT NULL,
    [LastName] [nvarchar](128) NOT NULL,
    [TwitterName] [nvarchar](128),
    [EmailAddress] [nvarchar](128) NOT NULL,
    [WebsiteUrl] [nvarchar](1024),
    [BlogUrl] [nvarchar](1024),
    [MobilePhone] [nvarchar](20),
    [ShirtSize] [nvarchar](10),
    [CreatedUTC] [datetime] NOT NULL,
    [UpdatedBy] [nvarchar](128),
    [UpdatedUTC] [datetime],
    [PrivateNotes] [nvarchar](1024),
    [OrganizerNotes] [nvarchar](1024),
    CONSTRAINT [PK_dbo.cc_Presenters] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_EventId] ON [dbo].[cc_Presenters]([EventId])
CREATE INDEX [IX_SiteUserId] ON [dbo].[cc_Presenters]([SiteUserId])
CREATE TABLE [dbo].[cc_SiteUsers] (
    [Id] [int] NOT NULL IDENTITY,
    [FirstName] [nvarchar](128) NOT NULL,
    [LastName] [nvarchar](128) NOT NULL,
    [EmailAddress] [nvarchar](128) NOT NULL,
    [UserIdentityIssuer] [nvarchar](256) NOT NULL,
    [UserIdentityProvider] [nvarchar](256) NOT NULL,
    [UserIdentityClaimType] [nvarchar](256) NOT NULL,
    [UserIdentityClaim] [nvarchar](512) NOT NULL,
    [UserClaimEmailAddress] [nvarchar](128),
    [IpAtSignup] [nvarchar](50),
    [IsApproved] [bit] NOT NULL,
    [IsLockedOut] [bit] NOT NULL,
    [LastLoginUTC] [datetime],
    [LastOnlineActivityUTC] [datetime],
    [Version] rowversion NOT NULL,
    [CreatedUTC] [datetime] NOT NULL,
    [CreatedBy] [nvarchar](128) NOT NULL,
    [UpdatedUTC] [datetime],
    [UpdatedBy] [nvarchar](128),
    CONSTRAINT [PK_dbo.cc_SiteUsers] PRIMARY KEY ([Id])
)
CREATE TABLE [dbo].[cc_SessionPresenters] (
    [PresenterId] [int] NOT NULL,
    [SessionId] [int] NOT NULL,
    [Event_Id] [int],
    CONSTRAINT [PK_dbo.cc_SessionPresenters] PRIMARY KEY ([PresenterId], [SessionId])
)
CREATE INDEX [IX_PresenterId] ON [dbo].[cc_SessionPresenters]([PresenterId])
CREATE INDEX [IX_SessionId] ON [dbo].[cc_SessionPresenters]([SessionId])
CREATE INDEX [IX_Event_Id] ON [dbo].[cc_SessionPresenters]([Event_Id])
CREATE TABLE [dbo].[cc_Sessions] (
    [Id] [int] NOT NULL IDENTITY,
    [EventId] [int] NOT NULL,
    [Title] [nvarchar](128) NOT NULL,
    [Description] [nvarchar](4000) NOT NULL,
    [SessionMaterialsUrl] [nvarchar](128),
    [CreatedUTC] [datetime] NOT NULL,
    [SessionStatusId] [int] NOT NULL,
    [DesiredRoomSize] [nvarchar](10),
    [UpdatedBy] [nvarchar](128),
    [UpdatedUTC] [datetime],
    [PrivateNotes] [nvarchar](1024),
    [OrganizerNotes] [nvarchar](1024),
    CONSTRAINT [PK_dbo.cc_Sessions] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_EventId] ON [dbo].[cc_Sessions]([EventId])
CREATE TABLE [dbo].[cc_ScheduledSessions] (
    [Id] [int] NOT NULL IDENTITY,
    [RoomId] [int] NOT NULL,
    [SessionId] [int] NOT NULL,
    [TimeslotId] [int] NOT NULL,
    CONSTRAINT [PK_dbo.cc_ScheduledSessions] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_RoomId] ON [dbo].[cc_ScheduledSessions]([RoomId])
CREATE INDEX [IX_SessionId] ON [dbo].[cc_ScheduledSessions]([SessionId])
CREATE INDEX [IX_TimeslotId] ON [dbo].[cc_ScheduledSessions]([TimeslotId])
CREATE TABLE [dbo].[cc_Rooms] (
    [Id] [int] NOT NULL IDENTITY,
    [BuildingId] [int] NOT NULL,
    [Name] [nvarchar](128) NOT NULL,
    [Floor] [int],
    [Capacity] [int] NOT NULL,
    [ShowToPublic] [bit] NOT NULL,
    CONSTRAINT [PK_dbo.cc_Rooms] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_BuildingId] ON [dbo].[cc_Rooms]([BuildingId])
CREATE TABLE [dbo].[cc_TimeSlots] (
    [Id] [int] NOT NULL IDENTITY,
    [EventId] [int] NOT NULL,
    [Name] [nvarchar](128) NOT NULL,
    [Date] [datetime] NOT NULL,
    [StartTime] [time](7) NOT NULL,
    [EndTime] [time](7) NOT NULL,
    CONSTRAINT [PK_dbo.cc_TimeSlots] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_EventId] ON [dbo].[cc_TimeSlots]([EventId])
CREATE TABLE [dbo].[cc_SessionTags] (
    [Id] [int] NOT NULL IDENTITY,
    [SessionId] [int] NOT NULL,
    [TagId] [int] NOT NULL,
    CONSTRAINT [PK_dbo.cc_SessionTags] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_SessionId] ON [dbo].[cc_SessionTags]([SessionId])
CREATE INDEX [IX_TagId] ON [dbo].[cc_SessionTags]([TagId])
CREATE TABLE [dbo].[cc_Tags] (
    [Id] [int] NOT NULL IDENTITY,
    [EventId] [int] NOT NULL,
    [Name] [nvarchar](128) NOT NULL,
    CONSTRAINT [PK_dbo.cc_Tags] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_EventId] ON [dbo].[cc_Tags]([EventId])
CREATE TABLE [dbo].[cc_SpeakerRateSpeakers] (
    [Id] [int] NOT NULL IDENTITY,
    [PresenterId] [int] NOT NULL,
    [SpeakerUrl] [nvarchar](256),
    CONSTRAINT [PK_dbo.cc_SpeakerRateSpeakers] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_PresenterId] ON [dbo].[cc_SpeakerRateSpeakers]([PresenterId])
CREATE TABLE [dbo].[cc_PresenterBiographies] (
    [Id] [int] NOT NULL IDENTITY,
    [PresenterId] [int] NOT NULL,
    [Content] [nvarchar](4000) NOT NULL,
    CONSTRAINT [PK_dbo.cc_PresenterBiographies] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_PresenterId] ON [dbo].[cc_PresenterBiographies]([PresenterId])
CREATE TABLE [dbo].[cc_SpeakerRateEvent] (
    [Id] [int] NOT NULL IDENTITY,
    [EventId] [int] NOT NULL,
    [EventUrl] [nvarchar](256),
    CONSTRAINT [PK_dbo.cc_SpeakerRateEvent] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_EventId] ON [dbo].[cc_SpeakerRateEvent]([EventId])
CREATE TABLE [dbo].[cc_Sponsors] (
    [Id] [int] NOT NULL IDENTITY,
    [ImageUrl] [nvarchar](1024) NOT NULL,
    [ImageHeight] [int] NOT NULL,
    [ImageWidth] [int] NOT NULL,
    [EventId] [int] NOT NULL,
    [Name] [nvarchar](128) NOT NULL,
    [Url] [nvarchar](1024) NOT NULL,
    CONSTRAINT [PK_dbo.cc_Sponsors] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_EventId] ON [dbo].[cc_Sponsors]([EventId])
CREATE TABLE [dbo].[cc_Tasks] (
    [Id] [int] NOT NULL IDENTITY,
    [EventId] [int] NOT NULL,
    [Name] [nvarchar](128) NOT NULL,
    [Notes] [nvarchar](1024),
    CONSTRAINT [PK_dbo.cc_Tasks] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_EventId] ON [dbo].[cc_Tasks]([EventId])
CREATE TABLE [dbo].[cc_Tasks_TimeSlots] (
    [Id] [int] NOT NULL IDENTITY,
    [TaskId] [int] NOT NULL,
    [TaskTimeslotId] [int] NOT NULL,
    CONSTRAINT [PK_dbo.cc_Tasks_TimeSlots] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_TaskId] ON [dbo].[cc_Tasks_TimeSlots]([TaskId])
CREATE INDEX [IX_TaskTimeslotId] ON [dbo].[cc_Tasks_TimeSlots]([TaskTimeslotId])
CREATE TABLE [dbo].[cc_TaskTimeSlots] (
    [Id] [int] NOT NULL IDENTITY,
    [Date] [datetime] NOT NULL,
    [StartTime] [time](7) NOT NULL,
    [EndTime] [time](7) NOT NULL,
    [VolunteersNeeded] [int] NOT NULL,
    CONSTRAINT [PK_dbo.cc_TaskTimeSlots] PRIMARY KEY ([Id])
)
CREATE TABLE [dbo].[aspnetRgs_log4net] (
    [LogEntryID] [bigint] NOT NULL IDENTITY,
    [Application] [varchar](50) NOT NULL,
    [LogTimeLocal] [datetime] NOT NULL,
    [LogDbTimeUTC] [datetime] NOT NULL,
    [Level] [nvarchar](10) NOT NULL,
    [Logger] [varchar](60) NOT NULL,
    [UserName] [varchar](100),
    [RemoteIP] [varchar](39),
    [MachineName] [varchar](100),
    [ThreadId] [int],
    [SessionId] [varchar](80),
    [URL] [varchar](512),
    [Message] [varchar](3072) NOT NULL,
    [Exception] [varchar](2000),
    CONSTRAINT [PK_dbo.aspnetRgs_log4net] PRIMARY KEY ([LogEntryID])
)
CREATE TABLE [dbo].[cc_Roles] (
    [Id] [int] NOT NULL IDENTITY,
    [RoleName] [nvarchar](128) NOT NULL,
    CONSTRAINT [PK_dbo.cc_Roles] PRIMARY KEY ([Id])
)
CREATE TABLE [dbo].[cc_Roles4Events] (
    [Id] [int] NOT NULL IDENTITY,
    [RoleName] [nvarchar](128) NOT NULL,
    CONSTRAINT [PK_dbo.cc_Roles4Events] PRIMARY KEY ([Id])
)
CREATE TABLE [dbo].[cc_UsersInEventRoles] (
    [Role4EventId] [int] NOT NULL,
    [SiteUserId] [int] NOT NULL,
    [EventId] [int] NOT NULL,
    [CreatedUTC] [datetime] NOT NULL,
    [CreatedBy] [nvarchar](128) NOT NULL,
    CONSTRAINT [PK_dbo.cc_UsersInEventRoles] PRIMARY KEY ([Role4EventId], [SiteUserId])
)
CREATE INDEX [IX_Role4EventId] ON [dbo].[cc_UsersInEventRoles]([Role4EventId])
CREATE INDEX [IX_SiteUserId] ON [dbo].[cc_UsersInEventRoles]([SiteUserId])
CREATE INDEX [IX_EventId] ON [dbo].[cc_UsersInEventRoles]([EventId])
CREATE TABLE [dbo].[cc_UsersInRoles] (
    [RoleId] [int] NOT NULL,
    [SiteUserId] [int] NOT NULL,
    [CreatedUTC] [datetime] NOT NULL,
    [CreatedBy] [nvarchar](128) NOT NULL,
    CONSTRAINT [PK_dbo.cc_UsersInRoles] PRIMARY KEY ([RoleId], [SiteUserId])
)
CREATE INDEX [IX_RoleId] ON [dbo].[cc_UsersInRoles]([RoleId])
CREATE INDEX [IX_SiteUserId] ON [dbo].[cc_UsersInRoles]([SiteUserId])
CREATE TABLE [dbo].[cc_SpeakerRateTalks] (
    [Id] [int] NOT NULL IDENTITY,
    [SessionId] [int] NOT NULL,
    [TalkUrl] [nvarchar](256),
    CONSTRAINT [PK_dbo.cc_SpeakerRateTalks] PRIMARY KEY ([Id])
)
CREATE INDEX [IX_SessionId] ON [dbo].[cc_SpeakerRateTalks]([SessionId])
CREATE TABLE [dbo].[cc_SponsorImages] (
    [Id] [int] NOT NULL IDENTITY,
    [ImageUrl] [nvarchar](1024) NOT NULL,
    [ImageHeight] [int] NOT NULL,
    [ImageWidth] [int] NOT NULL,
    CONSTRAINT [PK_dbo.cc_SponsorImages] PRIMARY KEY ([Id])
)
ALTER TABLE [dbo].[cc_Buildings] ADD CONSTRAINT [FK_dbo.cc_Buildings_dbo.cc_Events_EventId] FOREIGN KEY ([EventId]) REFERENCES [dbo].[cc_Events] ([Id])
ALTER TABLE [dbo].[cc_CommunitySponsors] ADD CONSTRAINT [FK_dbo.cc_CommunitySponsors_dbo.cc_Events_EventId] FOREIGN KEY ([EventId]) REFERENCES [dbo].[cc_Events] ([Id])
ALTER TABLE [dbo].[cc_IndividualContributors] ADD CONSTRAINT [FK_dbo.cc_IndividualContributors_dbo.cc_Events_EventId] FOREIGN KEY ([EventId]) REFERENCES [dbo].[cc_Events] ([Id])
ALTER TABLE [dbo].[cc_Presenters] ADD CONSTRAINT [FK_dbo.cc_Presenters_dbo.cc_Events_EventId] FOREIGN KEY ([EventId]) REFERENCES [dbo].[cc_Events] ([Id])
ALTER TABLE [dbo].[cc_Presenters] ADD CONSTRAINT [FK_dbo.cc_Presenters_dbo.cc_SiteUsers_SiteUserId] FOREIGN KEY ([SiteUserId]) REFERENCES [dbo].[cc_SiteUsers] ([Id])
ALTER TABLE [dbo].[cc_SessionPresenters] ADD CONSTRAINT [FK_dbo.cc_SessionPresenters_dbo.cc_Presenters_PresenterId] FOREIGN KEY ([PresenterId]) REFERENCES [dbo].[cc_Presenters] ([Id])
ALTER TABLE [dbo].[cc_SessionPresenters] ADD CONSTRAINT [FK_dbo.cc_SessionPresenters_dbo.cc_Sessions_SessionId] FOREIGN KEY ([SessionId]) REFERENCES [dbo].[cc_Sessions] ([Id])
ALTER TABLE [dbo].[cc_SessionPresenters] ADD CONSTRAINT [FK_dbo.cc_SessionPresenters_dbo.cc_Events_Event_Id] FOREIGN KEY ([Event_Id]) REFERENCES [dbo].[cc_Events] ([Id])
ALTER TABLE [dbo].[cc_Sessions] ADD CONSTRAINT [FK_dbo.cc_Sessions_dbo.cc_Events_EventId] FOREIGN KEY ([EventId]) REFERENCES [dbo].[cc_Events] ([Id])
ALTER TABLE [dbo].[cc_ScheduledSessions] ADD CONSTRAINT [FK_dbo.cc_ScheduledSessions_dbo.cc_Rooms_RoomId] FOREIGN KEY ([RoomId]) REFERENCES [dbo].[cc_Rooms] ([Id])
ALTER TABLE [dbo].[cc_ScheduledSessions] ADD CONSTRAINT [FK_dbo.cc_ScheduledSessions_dbo.cc_Sessions_SessionId] FOREIGN KEY ([SessionId]) REFERENCES [dbo].[cc_Sessions] ([Id])
ALTER TABLE [dbo].[cc_ScheduledSessions] ADD CONSTRAINT [FK_dbo.cc_ScheduledSessions_dbo.cc_TimeSlots_TimeslotId] FOREIGN KEY ([TimeslotId]) REFERENCES [dbo].[cc_TimeSlots] ([Id])
ALTER TABLE [dbo].[cc_Rooms] ADD CONSTRAINT [FK_dbo.cc_Rooms_dbo.cc_Buildings_BuildingId] FOREIGN KEY ([BuildingId]) REFERENCES [dbo].[cc_Buildings] ([Id])
ALTER TABLE [dbo].[cc_TimeSlots] ADD CONSTRAINT [FK_dbo.cc_TimeSlots_dbo.cc_Events_EventId] FOREIGN KEY ([EventId]) REFERENCES [dbo].[cc_Events] ([Id])
ALTER TABLE [dbo].[cc_SessionTags] ADD CONSTRAINT [FK_dbo.cc_SessionTags_dbo.cc_Sessions_SessionId] FOREIGN KEY ([SessionId]) REFERENCES [dbo].[cc_Sessions] ([Id])
ALTER TABLE [dbo].[cc_SessionTags] ADD CONSTRAINT [FK_dbo.cc_SessionTags_dbo.cc_Tags_TagId] FOREIGN KEY ([TagId]) REFERENCES [dbo].[cc_Tags] ([Id])
ALTER TABLE [dbo].[cc_Tags] ADD CONSTRAINT [FK_dbo.cc_Tags_dbo.cc_Events_EventId] FOREIGN KEY ([EventId]) REFERENCES [dbo].[cc_Events] ([Id])
ALTER TABLE [dbo].[cc_SpeakerRateSpeakers] ADD CONSTRAINT [FK_dbo.cc_SpeakerRateSpeakers_dbo.cc_Presenters_PresenterId] FOREIGN KEY ([PresenterId]) REFERENCES [dbo].[cc_Presenters] ([Id])
ALTER TABLE [dbo].[cc_PresenterBiographies] ADD CONSTRAINT [FK_dbo.cc_PresenterBiographies_dbo.cc_Presenters_PresenterId] FOREIGN KEY ([PresenterId]) REFERENCES [dbo].[cc_Presenters] ([Id])
ALTER TABLE [dbo].[cc_SpeakerRateEvent] ADD CONSTRAINT [FK_dbo.cc_SpeakerRateEvent_dbo.cc_Events_EventId] FOREIGN KEY ([EventId]) REFERENCES [dbo].[cc_Events] ([Id])
ALTER TABLE [dbo].[cc_Sponsors] ADD CONSTRAINT [FK_dbo.cc_Sponsors_dbo.cc_Events_EventId] FOREIGN KEY ([EventId]) REFERENCES [dbo].[cc_Events] ([Id])
ALTER TABLE [dbo].[cc_Tasks] ADD CONSTRAINT [FK_dbo.cc_Tasks_dbo.cc_Events_EventId] FOREIGN KEY ([EventId]) REFERENCES [dbo].[cc_Events] ([Id])
ALTER TABLE [dbo].[cc_Tasks_TimeSlots] ADD CONSTRAINT [FK_dbo.cc_Tasks_TimeSlots_dbo.cc_Tasks_TaskId] FOREIGN KEY ([TaskId]) REFERENCES [dbo].[cc_Tasks] ([Id])
ALTER TABLE [dbo].[cc_Tasks_TimeSlots] ADD CONSTRAINT [FK_dbo.cc_Tasks_TimeSlots_dbo.cc_TaskTimeSlots_TaskTimeslotId] FOREIGN KEY ([TaskTimeslotId]) REFERENCES [dbo].[cc_TaskTimeSlots] ([Id])
ALTER TABLE [dbo].[cc_UsersInEventRoles] ADD CONSTRAINT [FK_dbo.cc_UsersInEventRoles_dbo.cc_Roles4Events_Role4EventId] FOREIGN KEY ([Role4EventId]) REFERENCES [dbo].[cc_Roles4Events] ([Id]) --ON DELETE CASCADE
ALTER TABLE [dbo].[cc_UsersInEventRoles] ADD CONSTRAINT [FK_dbo.cc_UsersInEventRoles_dbo.cc_SiteUsers_SiteUserId] FOREIGN KEY ([SiteUserId]) REFERENCES [dbo].[cc_SiteUsers] ([Id]) --ON DELETE CASCADE
ALTER TABLE [dbo].[cc_UsersInEventRoles] ADD CONSTRAINT [FK_dbo.cc_UsersInEventRoles_dbo.cc_Events_EventId] FOREIGN KEY ([EventId]) REFERENCES [dbo].[cc_Events] ([Id]) --ON DELETE CASCADE
ALTER TABLE [dbo].[cc_UsersInRoles] ADD CONSTRAINT [FK_dbo.cc_UsersInRoles_dbo.cc_Roles_RoleId] FOREIGN KEY ([RoleId]) REFERENCES [dbo].[cc_Roles] ([Id]) --ON DELETE CASCADE
ALTER TABLE [dbo].[cc_UsersInRoles] ADD CONSTRAINT [FK_dbo.cc_UsersInRoles_dbo.cc_SiteUsers_SiteUserId] FOREIGN KEY ([SiteUserId]) REFERENCES [dbo].[cc_SiteUsers] ([Id]) --ON DELETE CASCADE
ALTER TABLE [dbo].[cc_SpeakerRateTalks] ADD CONSTRAINT [FK_dbo.cc_SpeakerRateTalks_dbo.cc_Sessions_SessionId] FOREIGN KEY ([SessionId]) REFERENCES [dbo].[cc_Sessions] ([Id]) --ON DELETE CASCADE

--USE CodeCamp;
--ALTER TABLE [dbo].[__MigrationHistory] DROP COLUMN CreatedOn;

CREATE TABLE [dbo].[__MigrationHistory] (
    [MigrationId] [nvarchar](255) NOT NULL,
    [Model] [varbinary](max) NOT NULL,
    [ProductVersion] [nvarchar](32) NOT NULL,
    CONSTRAINT [PK_dbo.__MigrationHistory] PRIMARY KEY ([MigrationId])
)
BEGIN TRY
    EXEC sp_MS_marksystemobject 'dbo.__MigrationHistory'
END TRY
BEGIN CATCH
END CATCH

--USE CodeCamp;


INSERT INTO [__MigrationHistory] ([MigrationId], [Model], [ProductVersion]) VALUES ('201302090020256_Schema_2_0_EF44Initial', 0x1F8B0800000000000400ED5DDD6EDC3A92BE5F60DFC1F0E50093767C7232390367068E9DCC1863C786DB39E7D290BBE9B610B5D42BA99D645E6D2EF691F61556D42F45569145FDB7D31709DC22552C56158B7F559FFEEF3FFF7BF2F7EF6BEFE09985911BF8EF0F5FBF3A3A3C60FE2258BAFEEAFDE1367EFCF3BBC3BFFFEDBFFFEBE4E372FDFDE0F7A2DE31AF97BCE947EF0F9FE278F3D7D92C5A3CB1B513BD5ABB8B308882C7F8D52258CF9C65303B3E3A7A377B7D34630989C384D6C1C1C9EDD68FDD354B7F243FCF027FC136F1D6F1AE8225F3A2FC7952324FA91E7C76D62CDA380BF6FEF02CA971E6AC37AF3E7E3A3FBD3C3C38F55C27E162CEBC474B968E7EE32C1D968D25CD7D4CD88A7FDCFDD8B0B4C9F7871F1CDF67CB3B6725564B2AFE8BFDA83D481EDD84C18685F18F5BF698BF7CB13C3C98D5DF9BC92F96AF09EFF0F693BFFCF897E3C383CF5BCF731EBCE4C1A3E345ECF060F3F6AFF33808D93F98CF422766CB1B278E59E8F37759CA7F2E87BF6EDED244F1DBECE8988B62967436889D3851B1C2B8C426FFBF60741E8789B51C1E7C72BFB3E525F357F153C9EC95F3BD78F2FAF8DDE1C117DF4D8C2B79290EB70CE89CD8EAC9AC52875E495BD7E306BBD7518DCD8FCF4953665EC75774D2EA67E7D95DA5BD823A717870CBBCB4347A7237D9607F5568FD3EAFF2290CD6B78127D84356723F0FB6E1827722008BEF9C70C5623A47B741B08E408E78C97D698C0243B582B2C1829F7A69C16DA3919089623F0C4436CFDD68E3393F063264A9F1F95310C60D9AE6E26CD772DEEDF344EC966DBF7DD351DB97C122D7D0D062BF652B378AC3B4F52FA13782DE59C4574AF3EDC3DA4DFF8AAE37AC140457CA9DBBEE82EC991744AC35DD6CAA886EB60F9EBB28A87D0812F7E4F84DB53F4F2CFF3A5CB2B0E48E2DDCB59328E3264CFECA179C89A4E70B87D3B69F9B52AEE7B113C6A295371642C2F72248967B0BEEA8421625C45998D479743D769615243C9F7A5EF08D2DDB0A892F6C975B8F7525F49BD00DC2542039C7B76C1BB18E98FD9C4C8229977903ECD965DFF8E465EBD58E34E32AFBAD67E474C5FCA5D395CC0A1DFC9E1863F2D65D506A3DEA8AF4CDF2B181FFF98BCEFB837242572BC5BA025EB190D750F29A05596251B93A0BD6EBAD9FCCFFF34DC24F10C2DCC9B5542EE11A0AB748355BAE2FFCA5FBEC2E936D6AE20E12553E6C638C75B0AACABFA69AD2095D5DDB9E88860E705F16AB1C4B450A9772B92D67F90C07F39517AA5CD50A149EEAA50D3932882CA7ADD6AD9844AA28FB13AC9EED4665BE61CE5716DE26F3614A1291A9540B102E584395325CCD5ADC3A8F803A02FDF86F37ECEF1CC47B26052A27E543858BAAC49E83E82BC642F415E2A1780A3051165973912CAA222F40ECA82805B8A995A81CD58B5BED7F6547BFDF0AEFEC8990D46A8355D4D1B1FD46B6C13954E3558AECF70D8B994603025C34EC4745F7A3E2931B464D0E7A3A181A97CE602D37181E1DAC84E581425935371A2DE5626B3F42BA1F217337665F22166AE8508E007E8E81262FBDBEB95CEB9D374E11F8C7B5E37AA7CB653236A2E17BFE077B88B8E1743DFD537AFEC10B56A3347C153CB81EBB790A7C5B751FB73D619B3FB9613C77FF6D6D676D1B3E0B19776F5FEECE5A1FE47ED92C39A90F3F061F2B79CB864E5028DD84EE73F2EAE72066D6A3AEBD015E872BC74F8C201CAAFD060B0B8B432A7901811D6291CF28F2A9CCC057550D62AD28D5705756B16690746625D7BAAFD63FEAD91A500B3B6883AADA1F0395A749F99FC6E3ABFC4FA4179A7ABAA32CB572E3B3D60F6EB00A9DCD93CB0CA7AE45C51F705774F5F0F358A872ABB396D2BAF76BE59F7E7D3AEE1A31DB55641ABE88A26D75E54C5D35FDFAB64B1E92A2647B3A3617679EE3AE39031360C392855F5FB70E7FE12CA44DF7669A9475D4C5E634594CAFFCEDC656026D97D317D1E96693D861FBCBFF8BE832587C65CBEB6DDC9614775097C1CAF53B5820735AD7BEE7FAEC7411BBCF89A57540340F702EFBE9FA4E984C1A3C3E791B86CC5FFCB84A35926ACFA8C4775673D459B0DE6C634EB6F739AAC3BD564EAAE3BD96CD36AF03B50FB8616C7F254FDC55E017F3CAC6A3D9F24F5AEB375906962FABEB41B07EDE6693D563ADA956C798150F5664CC8AEF678F26EF2E09DB39CB5D268DEFB2B286EB2250C3C87351B1D5697FC1D17EFFD2F959FF9D1B5B07077630239CB36811BA9B0631C76F8E8E742B2E1BCF7095682E749317BA0E3C1EF814B588354ECC661BB5358844336EC8963CD5618CC3E5FD89F0CF70224C0C0F446697A667C179A4EF521FB928D502A743A48E7A3C8955EC27B4B1D5546E3C226EC93B1A9C57956BF8154A314EC52AED16CC92D6F6EB0E25AD6EACB53912E8D8DD1A9F778EE617B29A1AA790660B2A2E0CACD5E97ABE8D0333B2AB5BCF534252692C57B5353C97E1A846A6CB9AAD7621A9C2F7AE00CA59D9CD48D54F5E108428E3A445BCB37116A9A85B39C3A7E0DB5DD03053CA984FD426015A1E59707A74CF0B309AA3352EBD6AEEB8910328BDD2DE09BC9058F54EB251D3BCD6ECCD8C52B3C45E7F694FA3C1D68B9CFD218F7D2439A4E7C16FB712303A0165CDD0E63C720F36D3D7B2DEB15F51B439FBA66F3D91130968776A91B466E22DAD02F295368CF394FD6BB1E6DD9BF82ECF764DA6077DA6A432292839943D9C0AE9CD5F731A248E8E668E5E092FDC8F869E2E6B33F1DADFC4E883A01ADEECF717C0AA386B4AB46BBB14A9329E746FBBFDD82ECF6D4B3D66FF17990D4DB793806534FA5D17DDDCD6EDEE71D27A5A82A444C675B79AFBC1A650171AF70A216234B4CE3D6201C0E6DA59759FFC478B7BE54DFF93B9ABA7B8DD984809FDE12EE3A70EC6D68EEC11E42888C9A237101165540FD01944034764D98FFA9762E9130E8F316205A9DB700546887EFC147D8DEE0D8841B53AF7E9389018938A413423B94EBBCB981AC1FDB05494DAFE1036FADA7D7C45663BDDD818340A303BB4E14F1BAB003402DD5168AA51F8EE2662A1C6DC7E84BCA49B3F391D2AF0B6C9BE9B85D167C696ACD3E1DA6076B01D1184D9A29B9BBBCB60953C0B1B1D8515EF5E9CDB8F0AF1DD52331CBE7B9AA3E374B3F1DC4690E0B574C8BCD836F730587165734C72AFF5104D889D3FF037BB08B4BF64CFCC7E7BD43A593C58ADAC5394DFB6D703CF3C6BB2343FD2364D09ABBA65EB64717E7163D9F22FBFB56DF8CA593CB93E1BA7D7774F2173962D41B7941B7822FFEF5AB3FFE5F6B255F278338525DD7556B6CAFAE5E82FDA9669D3F677FE25247B0F797C646B2A1611AA1EDBAFF3A4786EAFD170EEED13489CA137FB5B8D1DD0548A8DE1A7AA6A3AB02A6553F3A605E8455B3DD71B6B75196F06801CEE1C7C472110341926A50380765392D5DD8BD5ABCD145E4B395DD054ED144D4D6E07423FC0EA18996E8CAF4617B451C634F17670CF90916CE37306F23653F1332FD145686CB61CC6AAB59645889D56E53D8C7DC3B0A78C78F3606F124472E778FB8BBB9E22B5BDAFE3069168C3BBEB2600C678C355748124B57A5D4492A461077BFBDC879368ADE7348A82859B0AAF8C3B04BF6751E7E9A3BF3CA07DDC229333F4A18C44C45B2F76F99970F2F0FDE19F949E1B5B294FF8AB56F205579DF46B857462EE2CE476977E44807F2BD2F563756CB8FEC2DD381E890BE96DE2D8E2AA29DB914BCED986F97C7890844D6100DF36CECAC6A4B16F12D5C94C3022BD6DE93E0681A99EF465884AFFF0174F2C4C8DF44DB661EC8DC0CA00464750C0F42D4F460BC7B48F4287571A17629CE956857E376F184B429A1FC07A1081EE92C52048D79072D58D486776A3223B56A4ABED519DF2D1AB579D1B90CCC7A03624CB97D2387E1E31902569301C31B553001D05F5CB589C16064681F727D870476666E6660073330B9FC2841EDC7440BB33CC7808389A625D0D8C6A9CB90E6C7C38B3D9B579AE0EDA8269144170A9349AE1A9D04D04067D1108563832BD5809D8FE0056020A92D2AE888A348E3B0121745017A0072E13DC8B8C8B67E367F4A03D7AEBECCADDE87818C2EDE8044D69BF40DE9B8651C1E8881A952B67AB3D99968213699C21FB32308993316C4C123A69198E81B70F6469124411A6770CAFA8D27615864CB726EC1BD8C3AC88E0D607B01B5898D35F13E180516477A1E665F4E497D47077B3A9F6E599645EC6704DB2E0293C881949636ED544C828C3DE0AC48F52A6A414E4C67ADF06C2220F36DDA13C0CB7870384BB13535C09B384CE432AE692E02DEC8C4545691A6A3A931B1E62269305B70393581DEB8A30E66BB86F1DFA921AA096D6DEBAF72142DBC3FA0F4198A429C81971678F21FC930F8DCD33513787D363CF4A2827631C4BEFE00CA5453B43AD80047D2658828AAF676373A42F050F782542E06708EB232881C2C6F8D7225AD832CC2A68186680555438794D6E7DB59F781ECE0629FC0C60831425EC860DE64B49C9A347A8F921F521CB0357DE602080993C3ECD52A7F366738308CF46F0D320561B381F80C221CE0610D4DB50579A5A2E86F5FE80B077602F448A653586B036885C1D356075AC38D51D0D4F1510B2F0430F152E4BDCD1727C219B231405616BB03314B9E5410E5164E1ED864DC808523A75A27052752B1140C62CED05C544D39B61877683703090012102A69DB1640066533124E3AD1209EFAB27C3D2DE2BD5D0988632B4116E97080AA01ADEE8774C65D0917E86AB5783CC0C8BCCD219984475E0D90E6E7D00FB818539FD594F8317806998021E50695B86C1B0302502F4402DF2AB423A906D4B96ECB57FCE3C16B383D3059705FF125FB470966A4ADE2CE1A603B334F764001335EB8DC244F5D6646CD698B661C68DE8C55E9B24724CCF5647480331E98B7401327632080C1042B59D21FCA9ED0C3D35CB1CDB81EEE4545FBA7E832996F570236C667F156164129FAAE1298C0F66728A2EA813F5146C8D383B1327E61636B7CBD3F1B833F1EE4EC218840B662E463C17F0B22905086A76D704A2C150825DC6B64B431F06B04D83AE48F6396894CCC7149885632B246FB0B0846159B23367BD397F483F04F75D5D23F2B7E62C2E4E771CDF67CBECC3971F4BA897E2C4A62804AC4F22931F588054CA731F039174410351C8579086D765941388920A2663200AA25840941100110379E10E5F25295C961BC8149E11A2524D4626224A5801404CB9C6A711D5D03293503FD6ADD25252230C4479F61A4428CBF833BC2C7C824021509D6FD324830C3D3178D6C40D4C81F2AA1A9D05F20204C651EDBA08B97199D6C28570273ACBA8BF5023378C44518F417514E9913FA8067EA9467959B88101A9881508F4B4465ABB883110CB3F17016BB0FC868579C07920816C094E79F90DAA6FF1B0D64029F592C2B61B22A71C8AD068EAC99128498B10836D670B459A69A7F06F1AFBCE60FF6462C2D2039F670BB05AA13232DB42A756B5A5AC0115AEEC1B38D92B6B2E320E9C40B7B03179995B9704414A3ACC3240546488B35ABF28206742E7B0C58C46721458B33EC427036F0122D36273D53A81A173098C8BAB1E8D38303CAE7E45502DE17452808F4610F695B39136B250CE420462C2D2B4B5443488488064A8F849F5CDB4194149EC9CBA64D6088C809944D24273C9E1834903FA03F5011F48D522DD2C890106511DA606E8B806C7A6C6328C6423B09CEF2834BD86B16B0412C22EBABDC641D81548F3667C96BAEEB4082DA225A8FB369D496831594C72EE4240E5D6912023F0E44FDF1FF9F0AF3B49C9077E84D1D8405E12100620251D5446AD07085886C0B7B079D1480281C7E8C38FE0D00E14738123F6F45A5522F6BA331825468F22F9E6B38E084F804F3D2888013473403006AAD9672723E67908022EE8691095A9F6D0F881F3F0EB26AF64E28BBA33F557CDBDEF65ACD433C8F52A5772CC31058959E6ED542DE6951BA4D7C522D56CFA860C6AFD22D23C0C9A2E4F871912DADC5E4866E45C60EC960CCF06167B081D8DEAA447C9FFED6B79AFCD4DD56D1A8DB9ACF08E4F97CD0AF5B1760A4CD952EA1258FB1222965C09C88F948759EB992913D3E88749D4F091DAED6E124EB9D40F563439131B46507A263C400912332464F6320D9A8E47A9A7A2C6C350D219E870479F423E1CB8CA81B3E5A4858A922F579BA9D3BB16ED4247C990EBABA7729617D2656D3298C23B960E260B01BD1232520417408058BB918A6EB744CE7032F549B7636A272DED86A97ED7D65A7A52BE0D20305D464EAD27484E0EE5C44947A7CF11A5FBE2A42A096ABE49AD37848C13A167C085A14652842493DA519678ADD9B9EC74D706B4AC076DDF745708EDA436D47D02F2D54DB3B46C4DAC27EB1A6A385651DEA86C904070807D35145C950755146AF4B73CBABA95817944D90D26EA38B292C760B771D8070DB5DB003C70165BAF83A1B3F046200F9AA0ED03C060D976671CC5E7F2CAA8CCB2EC64364F3F4A983F38992555166C136F1DEF2A58322F2A0AAE9CCD864FC8D59BF99383F9C659F058863FCFF34F1ED2BE77F86E76F4DB6C9DD1982D6A7B543986B46C290E4267C5A4D22CB8F4931B46F1B9133B0F0EFF58E0D9720D5623C5A016ED29A1A8AAFE8AA895E215FE773DE2F5D5C74FE7A79742CCAA44A492E4A7A473EBC441A6FD64E26A087F37797BBE703C2704BE60791678DBB58F4721E36FF3FFEBEF674F540A27338979594433454692D1CA52A7E9A45C1FB6510972BB4AD108FA6A3F0A2973AA441268A2D50E2B365F21B4D02AB80622A81479AF1F7D9EBBD1C6737EA8EAA815D0E9CD9F823056A9098FAD79E35F070779CB0AACE95D068B74660269568574BAB76CE5F2BC04FE5EFA115C91AE526821CB6C7E9D6F1FD66E36D35E6F98C43656A74D2B675E10C9FAC32AD97A8EE866FBE0B90BC87F9445D61A9D27C6751D2EF9B21350A9506AC9ED3C76C258353FB9CC8ADF45904CA10BFE9DE6E2C039A9F3E87AEC2C2B48647BEA79C137B6543A63F3AA85FEF3CB6F58356A299DF24DE806612AAC9CCF5BB68D18D83B43558B7925F033467362ECD965DFB29D596DB2C1ABD1DB3A5D317FE9C07293CBECF5F1BB1BB90F1EBB0BC49B0948356045FBF66E968F8AF392CB26333BABD1CD2D266A25E7C97ECE36937829CB318C82623BD3321824B2BB85D5C0F96CF6A643A4336DFB4937BDAA11098FE9B42E1D8854F5743236A5BDD726DB111A5740B01DCDBBD3B6173153BD36E16832D8716AE35A1F46E9EE9B1B27AA5189D50A2C64BF765CEF74B94C742EAD04EA25748A7FB087880B5C76DDE2733AB50F5EB05248950FE974AE8287640178F314F892DC6A05365B52378CE7EEBF952D69F9984EEB2C64C9927FF9E5EEAC4E4C7C6E31676E96FCAD0F3FA499B37A6C4D4BE14C7C6EB5747F4E5EFB1CC42C5256EA42099DE275B872FC44DA2140532E9B8C87AF6E035A3878ECB283E0DFF157FB71EFD374A4DD3BBE6C8A61A9A02FA2682B9F1C40E5CDA82745C9E24E47BFAAD1AC8533CF71D7DCF8F026842A2DDA30D0B7A59DBE84AB16A9426FE362739AB8F795BFDD482342786E412D3ADD6C124DC90717E2731B6A97C1E22B5B5E6F63999C506037D62E8395EB2BEEBF5E6247F1DAF75C9F71809BE744C92069A00ABD8DDF13C7AA9CC3960FC79A94F3B7E44959783CD6A4DC64B930D6C44988FCA54FA032A64A8389D448025F0909DFB4A92F84341FBBC1E9091848C0013B4C6B5C2576A1BBE62ADBB59DED9D1BCB87CDF9238B6B02162D4277035C528905D6367795B889D075BC483DE7852A8CE5808BBBA6D889B711324EAA422BA9BA215BF2F4587537A814EE77712F6717A72483B6716832905603CF6624D18F8BE3C62D53289EF53B81E1CEB2FA7643DD63E2DF7418CD8CB2BCFA16A603E10610CC057EAD1F1329C289642AE2F3216F953E794120ED9DF34716B393B371388CA73437954FAD825BBEDD05E03579AD6432265BA55DB4305B2CD78460BAF8ABD35EC4B5375C2068C93256240D30E102942CAD7A6C21177FA9522A1F4EC65CC554F5F67B8E6621AEBA97FB31DA4E27544771DDC807D0C7F3492DB5DB4CAD03EAF3A70991851000DA0C5B1545B5C1F02510E947ED9D1F1465ECAB7B75E1F9644C01043268610B00EEADBD2D5088EC862DA46922BE7457503E9C8C15A88803DDB883A691F46612D39E01D2571407503D9D90E2DB4761360FBE1C38E632450256B4523DB5A4F44FE6AE9EE46B40B1C092DE1FEE327E02C8E5CFA7BC8E414F45A71D5B9AC142B45AD2AA7817A4352DF4DAB45D5A7B63004E9EA776E02C6169B4B40C9C12D1467404FAB196E283D0F57D28FC91683D15F484D8F0E5DF5175DFCDB19B06E685A8F8A1D5BEDB875E189DDF93D7939576B2BBFDCCD8520E00524B27638AC277295AD861F9010B7B1BC45FC5645DBC71712EC51A09CF2D12B436FC0B5E40B267ADC022282A5871E3E139A29EC29F506245F1FC81BFA94657D54A2C28B2672633973DB2E26A25872C16CFEC82FCD4E9BE7A6A9360BB4E66F88B1B39B3B6786A115BEE2C9E5C9FA96CD50A2CA6A8A790394B65722A9F8E730AFCE5F652123A7F6021A5A4D1F46B273509150F2D3CF0778EE0A18C3EE1F1647C650620D3C24D42D03E041709BFD6CFF4CCDB522DBF7A3A2D65BC697F8484A39D113583BDFC93EB4705E56AA124F96352F69A3252D009FC0DB8B3AD978C95D7D6D5A67BFC00E9710DB5231B6D659EF69609D9E498D6F8D35A91829FD6CDAD46FA75BA56971A30857E26A76EA314BCAFCA996EF970427A17BF0CD8FE6A23FB8460E3FB0DE4F5FD2587FA7C7813AA231ED6ED08C5CDD74387416FD8E6B570604768518103EDAB922359574615FEB2B7C04373F6D00F9D777A01DF95EFD376FA2CF0972EB794838BE8F3D6F3DE1F3E3A9E8CB885095406D754AD51C1D894AB9463217F52FE2E3136737CCB1AF0662A1C0EA3990A25CAB13665C0CBACCAE14191D59A48E94714B3F52B5EE1D5FC7FBC33CFE55BAAB2C295E3BB8F2C8AEF82AFCC7F7FC8F1380F0F4E3DD7893268542B28CFDF6647C733B65CCFA268E901409E7CC01591CE3094E5C9BF98A2AF428FD587EC21B5C82F9E002326FBACACCBFB9F8EE47FB0443D7CBD73E37044089FD76229A78707DC329C070EC99A5BC74C4B3EDB22660DF8CF4EB87872C2C3832BE7FB25F357F1D3FBC3D7C7EF0C44451FA8971D083AB9B3A22B7754421B13963E7026B1B3A2AFA14CB6129F4A5BC09CD450FEE5B829D3D9DD9686F4DB374D495728941DCB4441A3EC5AE6081C65D60CCF618BD3DBB7D66473F8C9967425E0C98CDA836B3FFE55A8C99C33B670D7FC4A2859772CDC2805FC7E9D88952F3392627BDB93B1275B0AC01255B2B980541CC9E6B40C6091CD096B5021751EE4486C280EB7C6766470C8F662053120DB932D701F755EE22FC7FAEE93E7353D86E2CE4E71D3585DA8448D8A3D3A36CD5F64D512300E7F66FD0AF84A1D2BB9825B1A666D8A1C44FCCCCA150FDB412A941963F216A212AEA11CD26953A4518784EA986F11FCD0C23D52F82EC1103BA65B0346D4D03EB65EA90820895A9E6DE98A77462D97B002CE46B75626626EE03C5228D5D1363A56BE0CBBD18A3CD9D1C3C8843BEBE777D0BFF6EA042100449D63F9F56DAB266E4A0CC41E1B115010FB6E45DBC2AFAFEDB7FD081A62B70E4F4446D4F16FEDED4590C4E69BD21A366273327544C4768E1D81406C47B44440CCC884C1B7E7E209E2F6929DF3661B73E95ACAA2C3695808DCE8DA1775360F77B454A04F92DADB59DA64A9BDB004EAA39792E639B6D6548B0D4FC5417322D5F52771CF64AB9417B270E960837A97C113763C6A6B50851ADA6F8E8E8E9A9A581DAFB0DBC9B043D7A8601636D7950253D8E9AE6CBF951A652BA58503DC59CF54200B8E3C918849A2542A64D5A9D07C3BAB2E11E16F62371539E25FE3C3D30AEAAF852DD600FEA8BB0FB221C199BA3B6B4C53BDF3EAE4CE5C4846CE28350B3D281291C9346C57B82F27B6AD9B89C0B1F26DF4A1FB62C43C8D514B377303D4DBCEEAA1AB7DB80014473FF06CB19035E1ADFDEC0A2901DBDA6D879B0C90971433DA819BAA20D40619182F2BA0A94A026A173D84502E32829A6B57CC046A6923A3CF86C059CA80715B2AC2D8CE5AED54D539E851930E0D6C67355B008BB5D91AD4C1C47AD82360605C3B2BF59DDE4AAB345418AFCE8D0046C3A219008E7F653604F1DDE2E06AD58B4DD460B5B2A6CC0104B44BFB1ABE564BABAB436BB52596816B91EF61A81CAEAA681830B7C89E6885BC85937D7D647D6954C170E1647FF9CD3AA451C4E3EA94DF0A9CABF181B2721E05B1F6CEFEFA8DA37469864D3D6E8824C502B34BA39AA37A0207CDE356085E38E5E32393722CEE5964F0949D9D372B38A7614EC93018ABBD008902D4A24BD1A4A8479382827850801EB3F8EB8DB5383E34E52D0CB5ED9A60909AA5F1B4B19B812C660AB6B2CB8AD6A232EDACAFEDE8E22D07761AF2AC15004BDA592DBCC803574CA102BA8D1499720FAD6292BDFF01F75F052C46DE3E478E79953FB9DA7AB1CB37A6496B899C94CE54244A5C13914AF5B04EE84F0AA1C48858C8759CA6B972980557C599BA095D7FE16E1CAFC6B6548B68995C8A253DB9E49C6D98CF4D4EEE1CA52D7CB1322BE94A83C4D4FB1A70915EE3722678FF9A5772CF456A6AE16E5B823ED17E9216012690F76F1670DEBA4812A9B1DB064248D79FA49594F7F4FD5B4695D32192119EEEB605A0808293D63A92945A69ADAC202AAD7A58D7D9D1AB57D3B300B88B5330021DA8F0207620675BDD6379578D75A8330725D7AB66624A612FC661A7B096D661821E05DBD467B38D622570D685A258489FBB661F605727641D5A40D5016C0383DD6DB98E304C2453B08CC116168DEC42072E3C9CCBE87F5169E16A7654EF3BB09C94D3F1EE8124AF4A6569A1A8AFEC8185CEE5ECBF9AF295C25EAC40ED614F46A0CD7444DA2CF208A7610C43AD1626601543AE169A18C6D8AB05C5369008BF4AAB6505519BD5C3DD320FCDB749A7611FBACFC30E6220DC73DD2358E90D2F1D7446419A8A3A52BED565424BE593672731857914851716D7FF4AD1CA93ECDA5AD1CAB38CBC582C536D073E47E059A700A5F4F1CEAF0690FC65A4B5D1D701950DA8B9C0C290953406A86A8A7AA76A61589DE7C9DCE378796780500482B5EC9C5B27EA76648FAE64950F7C8FA066B5D7C63B50FC02EE120CA9FC48ABE3DF26A829EFC35A0B90720FD2148A77DF5A4C380393B51639217F801365190200F12520E15D9B60F47807489B63CF360305B841716D2F249C6D77A2D8781AF0104BC7E8ABB476E40F765BC92A12C164355C25D8DF03F809967A32295AC8E6974989453D6D0D893AE940F7186A01D2628109301523305F0D8895644D36B9229882710C7945D0D04846BF2490D20BEFD17C4DF1A0BFAC523FEEAF1ECB7622F7ECDA3F671E8BD9C169FA813F8E91192D9CA59AE9C1BF638CF12167468ACC28653D5D5CC3C2EAC7C4B499A0489386D4CF312CACDB28D9176B5B4346DA36B1ACD1E36D65BBEA6861FB42CD69D25E6A0A0EAA9CFDB4F39E32E30D6A4088EDF43CC30D673556D3DA14EC6587E6B2E16D67F8196C77262F295FBFDBDBFB5EAC484618404E72B3B29D0F01D0C129603635681CC0C7EC6B6F811F276FB0B0CC5C5EB2F45B82E74EEC3C38913A99F1B7E62C2E42961CDF67CBF472F763990E5FC48055653CFE6DEDBC3F5C3E0489DEB39CFAC5E2BEAC110107015243654099DA4E598435935730B7922FE99426F2E708FDB4D44C5C4DC356DA51AB204DCA15CDAD2389BE0A0B483D840FB0B69919E1AE50614028431A15BF116F68A89A299576AA22A499A202A11525C9456D4DA982B5AA64EF105BC71B35B545684209C955DB52AA608D4A15CDAD6771A04A8BD963A4155E68A65C9D212AD4AB22A4055E619E54202B08F69262A15E4D243F0937A2A34E220B856DA85D012A615D52AA5A380D211800F71E4225931B29AABACC4A10D864A156310B21AF686C1C9B384CF305799AC8EE700003E28F510B8ABED2288BA7F6601B62055D6B16A3AF7E0101B64A6A93DE620994ABB65615412D39D1C667F1ED2ABAF782D59BE44F826BE4BB2FC035F2C7A86BF408862E9EC683F4DFE88D3B6DE50D7169A41C61292D2A359066D3095BA8486D5BDB2CA5455A63CA4647E73DB21A66E7C1EB519A1680C5500F9217EBDD485A496D51D869A80BF7FC78F540A824ADDFA10358E808B6EC58F944D92E41D929C26BD54379FF5AEF02A17B08D413D04D0A2854EBEE627B8CF475B5B075F775B846800CC83048AD05A1DDEEA434901AAD452283F80062D0E2FCB4EEBAB20D49DF139E76D8C56A13A5EB257690079E730A3C570F47EDAE069805E83615C6A54D27A0A33D98845AD8BD38CA1D1F4118C8191C7452A9F6625262C0C03600299070395A8FFB91EC0077731ADC89AE3A4BB192265D033114A02E9AC116A42BC0EA2823E5397BA0EB2872F492F55829ECBEEBBAD14D4217E866748F2D866A8F48900316C60566C00A1DA91E4E4814F53470A0FB9A3CF1E66B71FB61D3A06B52C233D0375D4A746B27666503CD3DB498DD8BBB693407B8CBD959389E145F4D1F77D9DD94A0B6AB40369F9CBE282A456570F0EE55799B909DC2499DED4DD42C88269AD22529427A23273576B7AA464FBC33CD02C5DDEDABA06C3CDD0ECB98BDD79958F043F83A11A1B84B6B11D3CEF4768226A8B55F7A225700B25DC067FA4DBA6F3859EAF340093A47EAEEF8484828027D1A9C6ED48153AB2E3972AFC61F74D21D397B06E99736C9C69E59E50DF5A6A57C572CEAA3CBBA953239B544E910DA1DD29A794891683222008950F327A4F5B07C3993AF8AABC71A6120B72D2909A5AC7371E88E0C69A1FE1D1D1C8E2B06B241F4E100C7E87A151F8D761A09A1564C5F317A4267917E76DF45B37D0F65DAFD76198B40D52FCBF060D56EB699F0FDAABC34CBCAC82228BEF553464B966527B3ECA6347F90FC8C83D059B1AB60C9BC287D7A32BBDDFAFC2360D9AF7316B9AB8AC44942D3678B5A746659E7C27F0C8A385189A3A28AF2C1CCD8593AB1731AC6EEA3B38893E205171B3F5FF9DDF1B6DC5FAC1FD8F2C2BFDEC69B6D9C7499AD1FBCDA2A9D079BEADA3F99293C9F5CA75FD38CBAE842C2A6CBBF9B76EDA7474325DF9F806F30212478146BFEFD2AAECB987FC76AF5A3A4F439F0898472F195C1B7776CBDF11262D1B53F779E19CE9B598675899D9CBB4EB25F5A47398DEAFDE467627ECBF5F7BFFD3F3679CAD497ED0100, '5.0.0.net40')
